package com.sumi.erp.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.sumi.erp.mapper.StockVirtualReportMapper;
import com.sumi.erp.domain.StockVirtualReport;
import com.sumi.erp.service.IStockVirtualReportService;

/**
 * 采购库存Service业务层处理
 * 
 * @author fgf67@163.com
 * @date 2024-06-27
 */
@Service
public class StockVirtualReportServiceImpl implements IStockVirtualReportService 
{
    @Autowired
    private StockVirtualReportMapper stockVirtualReportMapper;

    /**
     * 查询采购库存
     * 
     * @param id 采购库存主键
     * @return 采购库存
     */
    @Override
    public StockVirtualReport selectStockVirtualReportById(Long id)
    {
        return stockVirtualReportMapper.selectStockVirtualReportById(id);
    }

    /**
     * 查询采购库存列表
     * 
     * @param stockVirtualReport 采购库存
     * @return 采购库存
     */
    @Override
    public List<StockVirtualReport> selectStockVirtualReportList(StockVirtualReport stockVirtualReport)
    {
        return stockVirtualReportMapper.selectStockVirtualReportList(stockVirtualReport);
    }

    /**
     * 新增采购库存
     * 
     * @param stockVirtualReport 采购库存
     * @return 结果
     */
    @Override
    public int insertStockVirtualReport(StockVirtualReport stockVirtualReport)
    {
        return stockVirtualReportMapper.insertStockVirtualReport(stockVirtualReport);
    }

    /**
     * 修改采购库存
     * 
     * @param stockVirtualReport 采购库存
     * @return 结果
     */
    @Override
    public int updateStockVirtualReport(StockVirtualReport stockVirtualReport)
    {
        return stockVirtualReportMapper.updateStockVirtualReport(stockVirtualReport);
    }

    /**
     * 批量删除采购库存
     * 
     * @param ids 需要删除的采购库存主键
     * @return 结果
     */
    @Override
    public int deleteStockVirtualReportByIds(Long[] ids)
    {
        return stockVirtualReportMapper.deleteStockVirtualReportByIds(ids);
    }

    /**
     * 删除采购库存信息
     * 
     * @param id 采购库存主键
     * @return 结果
     */
    @Override
    public int deleteStockVirtualReportById(Long id)
    {
        return stockVirtualReportMapper.deleteStockVirtualReportById(id);
    }
}
